<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>练习</title>

    <style>
                  @font-face {
              font-family: myfont;
              src: url(./html&css/Coca-ColaCareFontKaiTi.TTF);
          }
          .myfont{
              font-family: myfont;
              font-weight: 900;
              text-align: center;
          }
        div{color: blue;}
        p{color:initial}
        p{font-style:italic;
           }
           p{ text-align: center;}
        .zilei{
           background-color: blue;
           width: 50px;
           height: 5em;
          
        }

    </style>
</head>
<body>
    <div class="myfont">父类元素
        <p class="zilei">子类元素</p>
    </div>
 
</body>
</html>